package com.hmdp.utils;

public class RedisConstants {

    public static final String LOGIN_CODE_KEY = "login:code:";  // 用户登录验证码key前缀
    public static final Long LOGIN_CODE_TTL = 2L;               // 验证码过期时间
    public static final String LOGIN_USER_KEY = "login:token:"; // 用户登录token前缀
    public static final Long LOGIN_USER_TTL = 30L;           // token过期时间

    public static final Long CACHE_NULL_TTL = 2L;               //  缓存空对象过期时间

    public static final Long CACHE_SHOP_TTL = 30L;              // 缓存店铺过期时间
    public static final String CACHE_SHOP_KEY = "cache:shop:";  // 缓存店铺key前缀
    public static final String CACHE_SHOP_TYPE_KEY = "cache:shopType:";  // 缓存店铺类型key前缀
    public static final String CACHE_PENETRATION_NULL_VALUE = ""; // 缓存穿透空值

    public static final String LOCK_SHOP_KEY = "lock:shop:";    // 分布式锁key前缀
    public static final Long LOCK_SHOP_TTL = 10L;               // 分布式锁过期时间

    public static final String SECKILL_STOCK_KEY = "seckill:stock:"; // 秒杀库存key前缀
    public static final String BLOG_LIKED_KEY = "blog:liked:";       // 博客点赞key前缀
    public static final String FOLLOWER_KEY = "follows:";           // 用户关注key前缀
    public static final String FEED_KEY = "feed:";                   // 粉丝推送key前缀
    public static final String SHOP_GEO_KEY = "shop:geo:";           // 店铺位置key前缀
    public static final Long Shop_FEO_DISTANCE = 5000L;            // 店铺距离key前缀
    public static final String USER_SIGN_KEY = "sign:";              // 用户签到key前缀

}
